package com.orientation.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.orientation.entity.Building;
import com.orientation.vo.BuildingRoomVo;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 * 报到 服务类
 * </p>
 *
 * @author xuandian
 * @since 2022-3-9
 */
public interface BuildingService extends IService<Building> {
    /**
     * 添加
     *
     * @param building
     */
    void insertBuild(Building building);

    /**
     * 修改
     *
     * @param building
     */
    void updateBuilding(@Param("building") Building building);

    /**
     * 分页查询显示
     *
     * @param pageNum
     * @param pageSize
     * @param region
     * @param name
     * @param type
     * @return
     */

    IPage<Building> getBuilding(Integer pageNum, Integer pageSize, String region, String name, String type);

    /**
     * 分页查询显示楼栋信息
     *
     * @param pageNum
     * @param pageSize
     * @param region
     * @param name
     * @param type
     * @return
     */
    Page<BuildingRoomVo> queryBuildingVo(Integer pageNum, Integer pageSize, String region, String name, String type);

    /**
     * @param region
     * @param name
     * @param type
     * @return
     */
    BuildingRoomVo createBuildingRoom(String region, String name, String type);

    /**
     * 下拉
     *
     * @return
     */
    List<Building> getAll();

    /**
     * @param type
     * @return
     */
    List<Building> queryBuildingType(String type);

    /**
     * 公寓名
     * @param type
     * @return
     */
    List<String> queryAreaList(String type);
}